package team.epos.utils.util;

import team.epos.utils.properties.ResourcesProperties;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

/**
 * Create by Vic Xu on 7/15/2018
 *
 * @author Vic Xu
 */
public class ResourcesUtil {

    private static Properties conf = new Properties();

    public static ResourcesProperties resourcesProperties;

    public static void init(InputStream in) {
        try {
            conf.load(in);
            resourcesProperties = PropertiesBeanUtil.getBean(ResourcesProperties.class, conf);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }

}
